<template>
  <div>
    <div style="margin-bottom: 5px; text-align: right">
      <el-button icon="el-icon-edit" type="primary" plain @click.prevent="toCreate">添加图书</el-button>
    </div>
    <book-list-view></book-list-view>
  </div>
</template>

<script>
import BookListView from "@/components/BookListView.vue";

export default {
  methods: {
    toCreate() {
      this.$store.commit("clean");
      this.$router.push("/editBook");
    }
  },
  components: {
    BookListView
  }
};
</script>
